package com.course_design.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import com.course_design.entity.Record;
import com.course_design.service.RecordService;


@Controller
public class RecordController {
	@Autowired
	private RecordService recordService;
	@RequestMapping("/queryRecord")
	@ResponseBody
	public Msg queryRecord(@RequestParam("classInfo")Integer classInfo) {
		List<Record> records=recordService.queryAllRecord(classInfo);
		return Msg.success("OK").add("record", records);
	}
}
